﻿@inherits ComponentBase

<div class="tree-menu">
    <Tree Items="InternalItems" ShowCheckbox="true" ShowIcon="true" @ref="MenusTree" />

    <div class="form-footer">
        <Button Color="Color.Secondary" Icon="fa fa-times" Text="关闭" OnClickWithoutRender="OnClickClose" />
        <Button Color="Color.Primary" Icon="fa fa-save" Text="保存" OnClickWithoutRender="OnClickSave" />
    </div>
</div>

@code {
    RenderFragment<Navigation> RenderTreeItem => item =>
    @<div class="d-flex flex-fill"><span class="flex-fill">@item.Name</span><span class="mx-3">@item.Order</span><span class="app-type">@item.IsResource.ToDescriptionString()</span><span class="app-text">@GetApp(item.Application)</span></div>;
}
